<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title>搜索结果页</title>
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <meta name="apple-touch-fullscreen" content="yes">
    <meta name="full-screen" content="yes">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="white">
    <meta name="format-detection" content="telephone=no"/>
    <meta name="format-detection" content="address=no">
    <script src="../../js/jquery-2.1.1.min.js"></script>
    <script type="text/javascript">
        var docEl = document.documentElement;
        var clientWidth = docEl.clientWidth;
        docEl.style.fontSize = (clientWidth / 10) + 'px';
        $(document).ready(function () {
            (function (doc, win) {
                var docEl = doc.documentElement,
                        resizeEvt = 'orientationchange' in window ? 'orientationchange' : 'resize',
                        recalc = function () {
                            var clientWidth = docEl.clientWidth;
                            docEl.style.fontSize = (clientWidth / 10) + 'px';
                        };

                if (!doc.addEventListener) return;
                win.addEventListener(resizeEvt, recalc, false);
                doc.addEventListener('DOMContentLoaded', recalc, false);
            })(document, window);
        });
    </script>
    <link rel="stylesheet" href="../../style/css/index.css"/>
</head>
<body>
<div style="background: #f7f7f7;width: 100%;height: 100%">
    <!--header-->
    <div class="header">
        <img onclick="history.go(-1);" class="back" src="../../style/images/sg_ic_back.png" alt=""/>

        <div class="search_box">
            <img src="../../style/images/sg_ic_search_1@2x.png" alt=""/>
            <input id="search" class="search_href" type="text" placeholder="搜索商品"/>
        </div>
    </div>
    <!-- content-->
    <ul class="tool_list">
        <li>
            <p>综合</p>
        </li>
        <li>
            <p>销售</p>
        </li>
        <li>
            <p>价格</p>
        </li>
        <li style="border: 0;">
            <p>最新</p>
        </li>
    </ul>
    <ul class="qiangt" id="qiangt">
        <!--<li>-->
        <!--<img class="foodImg1" src="../../updata/foodImg1.jpg" alt=""/>-->
        <!--<p class="price">￥99</p>-->
        <!--<p>-->
        <!--菲律宾进口香蕉，香甜可口-->
        <!--1kg，8-9只-->
        <!--</p>-->
        <!--</li>-->
        <!--<li>-->
        <!--<img class="foodImg1" src="../../updata/foodImg1.jpg" alt=""/>-->
        <!--<p class="price">￥99</p>-->
        <!--<p>-->
        <!--菲律宾进口香蕉，香甜可口-->
        <!--1kg，8-9只-->
        <!--</p>-->
        <!--</li>-->
        <!--<li>-->
        <!--<img class="foodImg1" src="../../updata/foodImg1.jpg" alt=""/>-->
        <!--<p class="price">￥99</p>-->
        <!--<p>-->
        <!--菲律宾进口香蕉，香甜可口-->
        <!--1kg，8-9只-->
        <!--</p>-->
        <!--</li>-->
        <!--<li>-->
        <!--<img class="foodImg1" src="../../updata/foodImg1.jpg" alt=""/>-->
        <!--<p class="price">￥99</p>-->
        <!--<p>-->
        <!--菲律宾进口香蕉，香甜可口-->
        <!--1kg，8-9只-->
        <!--</p>-->
        <!--</li>-->
    </ul>
    <div style="clear: both; width: 100%;height: 50px;"></div>
</div>
<script src="../../js/md5.js"></script>
<script src="../../js/md5_need.js"></script>
<script type="text/javascript" charset="utf-8">
    function dit() {
        var arr = {
            apiCode: '_search_001'
//            key:$("#searchCon").val()
        };
        http(arr, function (data) {
            console.log(data);
            var $info = data.info;
            var temp = '';
            $.each($info, function (i, n) {
                temp += '<li>';
                temp += '<a href="details.html?id=' + n.id + '">';
                temp += '<img class="foodImg1" src="' + n.img_path + '" alt=""/>';
                temp += '<p class="price">￥' + n.original_price + '</p>';
                temp += '<p style="font-size:12px;">' + n.sub_title + '</p>';
                temp += '</a>';
                temp += '</li>';
            });
            $("#qiangt").append(temp);

        });
    }
    dit();
    $("#search").focus(function () {
        window.location.href = "http://localhost:63342/外包/html/index/搜索页.html";
    })

</script>
</body>
</html>